using System;
using System.Collections.Generic;
using roster.Domain;

namespace roster
{
    public static class EnumerablePrinterExtension
    {
        public static void Print<T>(this IEnumerable<T> list)
        {
            list.Print(x => x.ToString());
        }

        public static void Print<T>(this IEnumerable<T> list, Func<T, string> format)
        {
            list.ForEach(x => Console.WriteLine(x));
        }
    }
}